<template>
  <div>
    <TopNav title="精彩跟帖" />
    <CommentMain
      :commentData="comment"
      v-for="comment in commentList"
      :key="comment.id"
    />
  </div>
</template>

<script>
import TopNav from "../components/TopNav";
import CommentMain from "../components/Main";
export default {
  data() {
    return {
      commentList: []
    };
  },
  components: {
    TopNav,
    CommentMain
  },
  created() {
    this.$axios({
      url: "/post_comment/" + this.$route.params.id
    }).then(res => {
      this.commentList = res.data.data;
    });
  }
};
</script>

<style>
</style>